/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package edu.chl.johanwi.jsfproducts;

import edu.chl.johanwi.jpa.nbp.Exceptions.NonexistentEntityException;
import java.util.ArrayList;
import javax.faces.bean.ManagedBean;
import javax.faces.bean.SessionScoped;
import javax.faces.context.FacesContext;

/**
 *
 * @author Schtohan
 */
@ManagedBean
@SessionScoped
public class viewCartControllerBean {

    private Product selected;

    public Product getSelected() {
        return selected;
    }

    public void setSelected(Product selected) {
        this.selected = selected;
    }
   
    /** Creates a new instance of viewCartControllerBean */
    public viewCartControllerBean() {
    }
    
    public String doEmpty(){
        
        FacesContext.getCurrentInstance().getExternalContext().invalidateSession();
        return "onViewProducts";
        
    }
}
